package ch.jamme.conf.def;

import java.lang.reflect.*;

import ch.jamme.conf.*;

/**
 * Defines a strategy to decide if a given field should be ignored during tha marshall phase
 * and then omitted from the produced XML.
 * @author Mario Fusco
 */
public class DefaultFieldSuppressionStrategy implements FieldSuppressionStrategy {

	/**
	 * Returns true if the marshall of the given field should be skipped
	 * @param field The field that's going to be marshalled
	 * @return True if the marshall of the given field should be skipped
	 */
	public boolean suppressField(Field field) {
		return false;
	}
	
	/**
	 * Returns true if the marshall of the given field having the given value for the object currently parsed should be skipped
	 * @param field The field that's going to be marshalled
	 * @param value The value of the field for the object currently parsed
	 * @return True if the marshall of the given field should be skipped
	 */
	public boolean suppressField(Field field, Object value) {
		return suppressField(field);
	}
}
